package com.example.demo.service;

import com.example.demo.dao.UserDao;
import com.example.demo.bean.User;
import com.example.demo.service.impl.UserServiceImpl;
import org.springframework.stereotype.Service;

import javax.annotation.Resource;

@Service("UserServiceImpl")
public class UserService implements UserServiceImpl {

    @Resource
    private UserDao userDao;

    @Override
    public User getUserById(int userId) {
        return userDao.selectById(userId);
    }

    @Override
    public int insertUser(User user) {
        return userDao.insertUser(user);
    }


}
